# coding=utf-8
from sqlalchemy import Column, Boolean, BigInteger, Float

from db_models.orm_base import BaseOrmClass


class CatAnswers(BaseOrmClass):
    '''
    模型(表)备注:回答
    '''
    __tablename__ = 'cat_answers'

    '''      '''
    id = Column(BigInteger(), primary_key=True)

    '''   问题ID   '''
    qid = Column(BigInteger(), nullable=False)

    '''   评估出来的能力值   '''
    theta = Column(Float(), nullable=False)

    '''   对或错(对1,错0)   '''
    answer = Column(Boolean(), nullable=False)

    '''   测试ID   '''
    test_id = Column(BigInteger(), nullable=False)

    def __repr__(self):
        return "cat_answers(qid='{self.qid}',theta='{self.theta}',answer='{self.answer}',test_id='{self.test_id}')".format(self=self)

    def exclude(self): return ()
